LibWeb: Remove per-element computed style overrides - #11022
Conversation
Element-specific computed style adjustments existed in the Rust style computation core and a virtual method on Element. The latter was still required for element-backed shadow pseudo-elements and animation style updates, so the two implementations could silently diverge over time. Expose a combined box transformation and element adjustment through the Rust FFI and use it for the remaining side paths and per-frame animation samples. Remove the Element virtual and its 20 HTML and SVG overrides. Adjusted animation samples preserve input and select line heights, SVG positioning, and table alignment throughout animated style updates.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (46)
💤 Files with no reviewable changes (41)
📝 WalkthroughWalkthroughThe change moves element-specific computed-style adjustments into Rust and shared ChangesElement style adjustment pipeline
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant StyleComputer
participant ComputedProperties
participant rust_adjust_element_style
StyleComputer->>ComputedProperties: collect animation results
StyleComputer->>rust_adjust_element_style: compute animated element adjustments
rust_adjust_element_style-->>StyleComputer: return combined adjustments
StyleComputer->>ComputedProperties: apply adjusted style properties
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
bf6c4c7
into
LadybirdBrowser:master
Element-specific computed style adjustments existed in the Rust style computation core and a virtual method on Element. The latter was still required for element-backed shadow pseudo-elements and animation style updates, so the two implementations could silently diverge over time.
Expose a combined box transformation and element adjustment through the Rust FFI and use it for the remaining side paths and per-frame animation samples. Remove the Element virtual and its 20 HTML and SVG overrides. Adjusted animation samples preserve input and select line heights, SVG positioning, and table alignment throughout animated style updates.